package org.apache.http.message;

import java.io.Serializable;
import org.apache.http.Header;
import org.apache.http.HeaderElement;
import org.apache.http.a.a;
import org.apache.http.annotation.Immutable;
import org.apache.http.d;

@Immutable
public class b implements Serializable, Cloneable, Header {
    private final String a;
    private final String b;

    public b(String str, String str2) {
        this.a = (String) a.a((Object) str, "Name");
        this.b = str2;
    }

    public Object clone() throws CloneNotSupportedException {
        return super.clone();
    }

    public HeaderElement[] getElements() throws d {
        return this.b != null ? e.a(this.b, null) : new HeaderElement[0];
    }

    public String getName() {
        return this.a;
    }

    public String getValue() {
        return this.b;
    }

    public String toString() {
        return f.b.formatHeader(null, this).toString();
    }
}
